home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Dr. Windows 3
/
dr win3.zip
/
dr win3
/
DATABASE
/
FOXRYAN.ZIP
/
VERIFY3.PRG
< prev
next >
Wrap
Text File
|
1993-07-05
|
1KB
|
54 lines
for m.i = 1 to 22
m.form = "form" + alltrim(str(m.i))
m.dbfile = m.form + ".dbf"
for m.j = 0 to 13
m.letter = iif(m.j = 0, "", chr(m.j-1+asc("A")))
m.scrfile = m.form + alltrim(m.letter) + ".scx"
?m.scrfile
select 0
if not file(m.scrfile)
exit
endif
use &scrfile alias screen
go top
locate for screen.objtype=12
do while not eof()
if inkey()=27
suspend
endif
delete file temp.tmp
copy memo screen.valid to temp.tmp
m.fp = fopen("temp.tmp", 0)
m.str = fread(m.fp, 100)
=fclose (m.fp)
m.k = strindex(upper(m.str), "FORM")
if m.k>0
m.l = strindex(upper(substr(m.str, m.k, len(str)-i+1)), ".") + m.k -1
m.after = right(m.str, len(m.str)-m.l + 1)
m.outstr = left(m.str, m.k+3) + alltrim(str(m.i)) + chr(m.j+asc("A"))) + m.after
m.fp = fopen("temp.tmp", 1)
=fwrite(m.fp, iif(screen.objtype=2, upper(m.outstr), m.outstr))
=fclose(m.fp)
append memo screen.valid from temp.tmp overwrite
endif
continue
enddo
use
endfor
endfor
function strindex
parameters bigstr, str
private l, i, bl
l = len(str)
bl = len(bigstr)
for i=1 to 1+bl-l
if substr(bigstr, i, l) = str
return i
endif
next
return 0